package com.headfirst.BehaviorMode.strategy.version4;

/**
 * 具体策略角色
 */
public class Div implements Operation{
    @Override
    public double op(double a, double b) {
        if(b != 0){
            return a/b;
        }else {
            throw new RuntimeException("除0了");
        }
    }
}
